﻿<Action runat="install" undo="false" alias="ExecuteSql" scriptfile="~/umbraco/commerce/install/CreateCommerceMemberData.sql" deleteSqlFileAfterExecute="false" ></Action>
<Action runat="install" undo="false" alias="ExecuteSql" scriptfile="~/umbraco/commerce/install/MacroProperties.sql" deleteSqlFileAfterExecute="false" ></Action>
<Action runat="install" undo="false" alias="ExecuteSql" scriptfile="~/umbraco/commerce/install/CreateFullSchema.sql" deleteSqlFileAfterExecute="false" ></Action>
<Action runat="install" undo="false" alias="ExecuteSql" scriptfile="~/umbraco/commerce/install/BaseData.sql" deleteSqlFileAfterExecute="false" ></Action>
<Action runat="install" undo="false" alias="ExecuteSql" scriptfile="~/umbraco/commerce/install/SampleData.sql" deleteSqlFileAfterExecute="false" ></Action>

<Action runat="install" undo="false" alias="EditMembershipConfig"></Action>
<Action runat="install" undo="false" alias="EditWebConfig"></Action>
<Action runat="install" undo="false" alias="AddAppConfigKey" key="discountTitle" value="Our Price"></Action>
<Action runat="install" undo="false" alias="AddAppConfigKey" key="discountDescription" value="Everyday Price"></Action>
<Action runat="install" undo="false" alias="AddAppConfigKey" key="tagLine" value="Powered by Commerce For Umbraco"></Action>
<Action runat="install" undo="false" alias="AddAppConfigKey" key="companyOrderIdentifier" value="C4U"></Action>
<Action runat="install" undo="false" alias="AddAppConfigKey" key="defaultCurrency" value="USD"></Action>
<Action runat="install" undo="false" alias="AddAppConfigKey" key="testServerName" value="yourtestserver.local"></Action>
<Action runat="install" undo="false" alias="AddAppConfigKey" key="useIntegrator" value="false"></Action>
<Action runat="install" undo="false" alias="AddAppConfigKey" key="orderMinimum" value="0"></Action>
<Action runat="install" undo="false" alias="AddAppConfigKey" key="newMemberRole" value="reseller"></Action>

<Action runat="install" alias="addApplication" appName="Commerce" appAlias="commerce" appIcon="commerce.png" />
<Action runat="install" alias="addApplicationTree" silent="false" initialize="true" sortOrder="0" 
	applicationAlias="commerce" treeAlias="orders" treeTitle="Orders" iconOpened="folder_o.gif" 
	iconClosed="folder.gif" assemblyName="CommerceForUmbraco.adminSection.trees" treeHandlerType="loadOrderTree" action="" />
<Action runat="install" alias="addApplicationTree" silent="false" initialize="true" sortOrder="1" 
	applicationAlias="commerce" treeAlias="products" treeTitle="Products" iconOpened="folder_o.gif" 
	iconClosed="folder.gif" assemblyName="CommerceForUmbraco.adminSection.trees" treeHandlerType="loadProductTree" action="" />	
<Action runat="install" alias="addApplicationTree" silent="false" initialize="true" sortOrder="2" 
	applicationAlias="commerce" treeAlias="categories" treeTitle="Categories" iconOpened="folder_o.gif" 
	iconClosed="folder.gif" assemblyName="CommerceForUmbraco.adminSection.trees" treeHandlerType="loadCategoryTree" action="" />
<Action runat="install" alias="addApplicationTree" silent="false" initialize="true" sortOrder="3" 
	applicationAlias="commerce" treeAlias="manufacturers" treeTitle="Manufacturers" iconOpened="folder_o.gif" 
	iconClosed="folder.gif" assemblyName="CommerceForUmbraco.adminSection.trees" treeHandlerType="loadManufacturerTree" action="" />
<Action runat="install" alias="addApplicationTree" silent="false" initialize="true" sortOrder="4" 
	applicationAlias="commerce" treeAlias="mailers" treeTitle="Mailers" iconOpened="folder_o.gif" 
	iconClosed="folder.gif" assemblyName="CommerceForUmbraco.adminSection.trees" treeHandlerType="loadMailerTree" action="" />
<Action runat="install" alias="addApplicationTree" silent="false" initialize="true" sortOrder="5" 
	applicationAlias="commerce" treeAlias="coupons" treeTitle="Coupons" iconOpened="folder_o.gif" 
	iconClosed="folder.gif" assemblyName="CommerceForUmbraco.adminSection.trees" treeHandlerType="loadCouponTree" action="" />	

<Action runat="install" undo="false" alias="AddTreeNodeType">
	<nodeType alias="initproducts">
		<header>Product</header>
		<usercontrol>/commerce/createproduct.ascx</usercontrol>
		<tasks>
			<create assembly="CommerceForUmbraco.adminSection" type="tasks.ProductTasks" />
		</tasks>
	</nodeType>
	<nodeType alias="products">
		<header>Product</header>
		<usercontrol>/commerce/createproduct.ascx</usercontrol>
		<tasks>
			<delete assembly="CommerceForUmbraco.adminSection." type="tasks.ProductTasks" />
			<create assembly="CommerceForUmbraco.adminSection" type="tasks.ProductTasks" />
		</tasks>
	</nodeType>
</Action>
<Action runat="install" undo="false" alias="AddTreeNodeType">
    <nodeType alias="initcategories">
    <header>Category</header>
    <usercontrol>/create/simple.ascx</usercontrol>
    <tasks>
      <create assembly="CommerceForUmbraco.adminSection" type="tasks.CategoryTasks" />
    </tasks>
    </nodeType>
    <nodeType alias="categories">
    <header>Category</header>
    <usercontrol>/create/simple.ascx</usercontrol>
    <tasks>
      <delete assembly="CommerceForUmbraco.adminSection." type="tasks.CategoryTasks" />
      <create assembly="CommerceForUmbraco.adminSection" type="tasks.CategoryTasks" />
    </tasks>
    </nodeType>
</Action>
<Action runat="install" undo="false" alias="AddTreeNodeType">
  <nodeType alias="initmanufacturers">
    <header>Manufacturer</header>
    <usercontrol>/create/simple.ascx</usercontrol>
    <tasks>
      <create assembly="CommerceForUmbraco.adminSection" type="tasks.ManufacturerTasks" />
    </tasks>
  </nodeType>
  <nodeType alias="manufacturers">
    <header>Manufacturer</header>
    <usercontrol>/create/simple.ascx</usercontrol>
    <tasks>
      <delete assembly="CommerceForUmbraco.adminSection." type="tasks.ManufacturerTasks" />
      <create assembly="CommerceForUmbraco.adminSection" type="tasks.ManufacturerTasks" />
    </tasks>
  </nodeType>
</Action>
<Action runat="install" undo="false" alias="AddTreeNodeType">
  <nodeType alias="initcoupons">
    <header>Coupon</header>
    <usercontrol>/commerce/createCoupon.ascx</usercontrol>
    <tasks>
      <create assembly="CommerceForUmbraco.adminSection" type="tasks.CouponTasks" />
    </tasks>
  </nodeType>
  <nodeType alias="coupons">
    <header>Coupon</header>
    <usercontrol>/commerce/createCoupon.ascx</usercontrol>
    <tasks>
      <delete assembly="CommerceForUmbraco.adminSection." type="tasks.CouponTasks" />
      <create assembly="CommerceForUmbraco.adminSection" type="tasks.CouponTasks" />
    </tasks>
  </nodeType>
</Action>  

<Action runat="install"
	alias="addDashboardSection" 
	dashboardAlias="CommerceDashboard">
  <section>
    <areas>
      <area>commerce</area>
    </areas>
    <tab caption="Overview">
      <control>commerce/dashboardOverview.ascx</control>
    </tab>
    <tab caption="Coupons">
      <control>commerce/dashboardCoupon.ascx</control>
    </tab>
  </section>
</Action>

<Action runat="install" alias="addXsltExtension" assembly="/bin/CommerceForUmbraco.xsltExtensions"
        type="CommerceForUmbraco.xsltExtensions.CommerceForUmbracoExtension" extensionAlias="c4u"></Action>

<Action runat="install" undo="false" alias="AddUrlRewriteRule">
	<add name="Commerce-rewriteProduct" virtualUrl="product/(.*).aspx" rewriteUrlParameter="ExcludeFromClientQueryString" destinationUrl="product.aspx?p=$1" ignoreCase="true" />
</Action>
<Action runat="install" undo="false" alias="AddUrlRewriteRule">
	<add name="Commerce-rewriteCatalog" virtualUrl="catalog/(.*).aspx" rewriteUrlParameter="ExcludeFromClientQueryString" destinationUrl="catalog.aspx?c=$1" ignoreCase="true" />
</Action>

<Action runat="install" undo="false" alias="ExecuteSql" scriptfile="~/umbraco/commerce/install/AddUmbracoUser2App.sql" deleteSqlFileAfterExecute="false" ></Action>

<!-- TODO:  lang.xml entries
  <area alias="sections">
    <key alias="commerce">Commerce</key>
  </area>
  <area alias="speechBubbles">
    <key alias="commerceItemSaved">Commerce Item Saved</key>
    <key alias="commerceItemErrorHeader">Commerce Item</key>
    <key alias="commerceItemErrorText">Save Failed</key>
  </area>
-->